<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%> 
<%

String menuid = (String)request.getParameter("menuid");
 %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html> 
<head> 
	<%@ include file="../../include.jsp"%>  
	<link rel="stylesheet" type="text/css" href="<%=basePath %>thirtpart/dhtmlx25/dhtmlxlayout.css">
	<link rel="STYLESHEET" type="text/css" href="<%=basePath %>thirtpart/dhtmlx25/dhtmlxtree.css">
	
    <link rel="stylesheet" type="text/css" href="<%=basePath %>thirtpart/dhtmlx25/skins/dhtmlxlayout_dhx_blue.css">
	<script src="<%=basePath %>thirtpart/dhtmlx25/dhtmlxcommon.js"></script>
	<script src="<%=basePath %>thirtpart/dhtmlx25/dhtmlxlayout.js"></script> 
	<script src="<%=basePath %>thirtpart/dhtmlx25/dhtmlxcontainer.js"></script>  
	<script  src="<%=basePath %>thirtpart/dhtmlx25/dhtmlxtree.js"></script>    
	<style>
		html, body {
			width: 100%;
			height: 100%;
			margin: 0px;
			padding: 0px;
			overflow: hidden;
		}
	</style>
	
</head>
<body onload="doOnLoad();"  >


<div id="treeboxbox_tree" style="width:100%; height:100%;background-color:#ccffcc;border :1px solid Silver;"></div>
 
	 
 
<script> 
function viewContent(itemId) {  
    var url = "<%=basePath%>dict/listDict.do?dicttype="+ itemId +"&menuid=<%=menuid%>"; 
      window.parent.dictmain.frameElement.src=url;
   // var obj = window.parent.frames["userlist"].src=url;
   // obj.document.location.relaod();
 }
function tonclick(id) {
    viewContent(id);
};
function tondblclick(id) {
    viewContent(id);
};

function tonopen(id, mode) {
    return confirm("Do you want to " + (mode > 0 ? "close": "open") + " node " + tree.getItemText(id) + "?");
}; 
function doOnLoad() {
   //tree
tree = new dhtmlXTreeObject("treeboxbox_tree", "100%", "100%", 0);
tree.enableTreeLines(true);
//tree.enableCheckBoxes(true);
tree.setSkin('dhx_skyblue');
tree.setImagePath("<%=basePath %>thirtpart/dhtmlx25/imgs/csh_winstyle/");
tree.enableDragAndDrop(0);
tree.enableTreeLines(true);
//tree.setImageArrays("plus", "", "", "", "plus.gif");
//tree.setImageArrays("minus", "", "", "", "minus.gif");
//tree.setStdImages("book.gif", "books_open.gif", "books_close.gif");
//tree.setImageArrays("plus", "", "", "", "", "plus.gif");
//tree.setImageArrays("minus", "", "", "", "", "minus.gif");
//tree.setStdImages("book.gif", "folderOpen.gif", "folderClosed.gif");
 
//tree.setOnOpenHandler(tonopen);
//tree.attachEvent("onOpenEnd", function(nodeId, event) {
//    doLog("An id of open item is " + nodeId);
//});
tree.setOnClickHandler(tonclick);
//tree.setOnCheckHandler(toncheck);
//tree.setOnDblClickHandler(tondblclick);


tree.setXMLAutoLoading("<%=basePath %>dict/listdicttree.do");
tree.loadXML("<%=basePath %>dict/listdicttree.do");
	
}
	</script>
</body>
</html>
<script>

</script>
